
package com.yanboo.modules.system.domain;

import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Getter;
import lombok.Setter;
import com.yanboo.common.base.BaseEntity;
import jakarta.persistence.*;
import jakarta.validation.constraints.NotBlank;
import java.io.Serializable;
import java.util.List;


@Entity
@Getter
@Setter
@Table(name="sys_dict")
public class Dict extends BaseEntity implements Serializable {

    @OneToMany(mappedBy = "dict",cascade={CascadeType.PERSIST,CascadeType.REMOVE})
    @org.hibernate.annotations.ForeignKey(name = "none")
    private List<DictDetail> dictDetails;

    @NotBlank
    @Schema(description = "名称")
    private String name;

    @Schema(description = "描述")
    private String description;
}